//导入请求工具类
import request from '@/utils/request.js'
//导入@/stores/token.js
// import { useTokenStore } from '@/store/token'

//文章分类列表查询
export const articleCategoryListService = ()=>{
    return request.get('/category')
}
//添加文章分类
export const articlaCategoryAddService = (categoryModel)=>{
    return request.post('/category',categoryModel)
}
//修改文章分类
export const articleCategoryUpdateService = (categoryModel)=>{
    return request.put('/category',categoryModel)
}
//删除文章分类
export const articleCategoryDeleteService = (id)=>{
    return request.delete('/category?id='+id)
}
//文章列表查询
export const articleListService = (params) => {
    return request.get('/article', { params: params })
}
//添加文章
export const articleAddService = (articleModel)=>{
    return request.post('/article',articleModel)
}